{template 'public/header'}

{template 'public/comhead'}

<link rel="stylesheet" type="text/css" href="../addons/yzzc_sun/template/public/ygcss.css">

<ul class="nav nav-tabs">
    <span class="ygxian"></span>
    <div class="ygdangq">当前位置:</div>
    <li class="active"><a href="javascript:void(0);">车辆信息</a></li>
    <li><a href="{php echo $this->createWebUrl('car');}"><i class="fa fa-refresh"></i>返回车辆列表</a></li>
</ul>
<div class="main ygmain">
    <form action="" method="post" class="form-horizontal form" enctype="multipart/form-data">
        <div class="panel panel-default ygdefault">

            <div class="panel-heading wyheader">

                车辆信息

            </div>

            <div class="panel-body">
                <!-- <div class="form-group">
                    <label class="col-xs-12 col-sm-3 col-md-2 control-label">选择门店</label>
                    <div class="col-sm-10">
                        <select name="sid">
                            {loop $shop $sval}
                            {if $info['sid']==$sval['id']}
                            <option value="{$sval['id']}" selected="selected">{$sval['name']}</option>
                            {else}
                            <option value="{$sval['id']}">{$sval['name']}</option>
                            {/if}
                            {/loop}
                        </select>
                    </div>
                </div> -->
                <div class="form-group">
                    <label class="col-xs-12 col-sm-3 col-md-2 control-label">默认排序</label>
                    <div class="col-sm-9">
                        <input type="number" name="sort" class="form-control" value="{$info['sort']}" />
                    </div>
                </div>
                <div class="form-group">
                    <label class="col-xs-12 col-sm-3 col-md-2 control-label">选择品牌</label>
                    <div class="col-sm-10">
                        <select name="carbrand" style='width:100px'>
                            {loop $shop $sval}
                            {if $info['carbrand']==$sval['id']}
                            <option value="{$sval['id']}" selected="selected">{$sval['name']}</option>
                            {else}
                            <option value="{$sval['id']}">{$sval['name']}</option>
                            {/if}
                            {/loop}
                        </select>
                    </div>
                </div>
                <div class="form-group">
                    <label class="col-xs-12 col-sm-3 col-md-2 control-label">选择所在地</label>
                    <div class="col-sm-10">
                        <select name="carcity" style='width:100px'>
                            {loop $cartype $sval}
                            {if $info['carcity']==$sval['id']}
                            <option value="{$sval['id']}" selected="selected">{$sval['name']}</option>
                            {else}
                            <option value="{$sval['id']}">{$sval['name']}</option>
                            {/if}
                            {/loop}
                        </select>
                    </div>
                </div>
                <div class="form-group">
                    <label class="col-xs-12 col-sm-3 col-md-2 control-label">车辆名称</label>
                    <div class="col-sm-9">
                        <input type="text" name="name" class="form-control" value="{$info['name']}"  />
                    </div>
                </div>
                <div class="form-group">
                    <label class="col-xs-12 col-sm-3 col-md-2 control-label">车牌号码</label>
                    <div class="col-sm-9">
                        <input type="text" name="carnum" class="form-control" value="{$info['carnum']}" />
                    </div>
                </div>
                <div class="form-group">
                    <label class="col-xs-12 col-sm-3 col-md-2 control-label">车牌类型</label>
                    <div class="col-sm-9">
                        <input type="text" name="cartype" class="form-control" value="{$info['cartype']}" placeholder="如轿车、SUV等等" />
                    </div>
                </div>
                <div class="form-group">
                    <label class="col-xs-12 col-sm-3 col-md-2 control-label">车身颜色</label>
                    <div class="col-sm-9">
                        <input type="text" name="color" class="form-control" value="{$info['color']}" />
                    </div>
                </div>
                <div class="form-group">
                    <label class="col-xs-12 col-sm-3 col-md-2 control-label">预约电话</label>
                    <div class="col-sm-9">
                        <input type="number" name="phone" class="form-control" value="{$info['phone']}" />
                    </div>
                </div>
                <div class="form-group">
                    <label class="col-xs-12 col-sm-3 col-md-2 control-label">里程</label>
                    <div class="col-sm-9">
                        <input type="number" name="mileage" class="form-control" value="{$info['mileage']}" />
                    </div>
                </div>
                <!-- <div class="form-group">
                    <label class="col-xs-12 col-sm-3 col-md-2 control-label">车辆结构</label>
                    <div class="col-sm-10">
                        <input type="radio" value="1" name="structure" {if $info['structure']==1 || empty($info['structure'])}checked{/if} >两厢
                        <input type="radio" value="2" name="structure" {if $info['structure']==2}checked{/if} >三厢
                    </div>
                </div> -->
                <div class="form-group">
                    <label class="col-xs-12 col-sm-3 col-md-2 control-label">变速箱</label>
                    <div class="col-sm-10">
                        <input type="radio" value="1" name="grarbox" {if $info['grarbox']==1 || empty($info['grarbox'])}checked{/if} >手动挡
                        <input type="radio" value="2" name="grarbox" {if $info['grarbox']==2 }checked{/if} >自动挡
                    </div>
                </div>
                <div class="form-group">
                    <label class="col-xs-12 col-sm-3 col-md-2 control-label">汽车排量</label>
                    <div class="col-sm-9">
                        <input type="text" name="displacement" class="form-control" value="{$info['displacement']}" placeholder="如1.5L、2L等" />
                    </div>
                </div>
                <div class="form-group">
                    <label class="col-xs-12 col-sm-3 col-md-2 control-label">过户次数</label>
                    <div class="col-sm-9">
                        <input type="number" name="num" class="form-control" value="{$info['num']}" />
                    </div>
                </div>

                <div class="form-group" id="datetimepicker">
                    <label class="col-xs-12 col-sm-3 col-md-2 control-label">上牌时间</label>

                    <div class="col-sm-9">
                        {php echo tpl_form_field_date('registrationtime',$info['registrationtime'],false)}
                    </div>
                </div>
                <div class="form-group">
                    <label class="col-xs-12 col-sm-3 col-md-2 control-label">首付</label>
                    <div class="col-sm-9">
                        <input type="text" name="money" class="form-control" value="{$info['money']}" />
                    </div>
                </div>
                <div class="form-group">
                    <label class="col-xs-12 col-sm-3 col-md-2 control-label">月供</label>
                    <div class="col-sm-9">
                        <input type="text" name="monthmoney" class="form-control" value="{$info['monthmoney']}" />
                    </div>
                </div>
                <div class="form-group">
                    <label class="col-xs-12 col-sm-3 col-md-2 control-label">官方指导价</label>
                    <div class="col-sm-9">
                        <input type="text" name="guidemoney" class="form-control" value="{$info['guidemoney']}" />
                    </div>
                </div>

                <div class="form-group">
                    <label class="col-xs-12 col-sm-3 col-md-2 control-label">是否推荐至首页</label>
                    <div class="col-sm-10">
                        <input type="radio" value="1" name="rec" {if $info['rec']==1 || empty($info['rec'])}checked{/if} >是
                        <input type="radio" value="2" name="rec" {if $info['rec']==2}checked{/if}>否
                    </div>
                </div>

                <div class="form-group">
                    <label class="col-xs-12 col-sm-3 col-md-2 control-label">封面图</label>
                    <div class="col-sm-9">
                        {php echo tpl_form_field_image('pic', $info['pic']);}
                        <span class="help-block">*建议比例 335*185</span>
                    </div>
                </div>
                <div class="form-group">
                    <label class="col-xs-12 col-sm-3 col-md-2 control-label">轮播图</label>
                    <div class="col-sm-9" style="width: 780px;">
                        {php echo tpl_form_field_multi_image('imgs',$lb_imgs);}
                        建议尺寸大小750*500
                    </div>

                </div>
                <div class="form-group" style="width: 90%;margin-left: 15px;">
                    <label class="col-xs-12 col-sm-3 col-md-2 control-label">二手车简介</label>
                    <div class="col-sm-10">
                        <!-- <textarea name="content" class="form-control" cols="30" rows="7">{$info['content']}</textarea> -->
                        {php echo tpl_ueditor('content',$info['content']);}

                    </div>
                </div>



      </div>
  </div>
        <div class="form-group">

            <input type="submit" name="submit" value="保存设置" class="btn col-lg-3" style="color: white;background-color: #444444;margin-left: 550px;"/>

            <input type="hidden" name="token" value="{$_W['token']}" />
             <input type="hidden" name="id" value="{$info['id']}" />

        </div>

    </form>

</div>
<script type="text/javascript">
    $(function(){
        $("#frame-8").show();
        $("#yframe-8").addClass("wyactive");
    })
</script>